Field of the Invention
The present invention relates to a method for storing and retrieving data in a control system, in particular in a motor vehicle, which system contains a computer, a RAM memory and a flash memory. These data are in particular operational data which can change while the control system, for example the motor-vehicle control system, is operating, and may constitute, for example, adaptive data for the optimized driving of components of the control system, for example an automatic transmission, error buffer data, the current kilometer reading, the overall length of operation etc. These operational data are determined and/or updated by the control system during ongoing operation and held ready in a RAM memory (direct access memory) for rapid access and rapid change. When the control system is switched off, the updated operational data are then stored in a nonvolatile memory, for example in an EEPROM and, when it is switched on again, they are read out of the EEPROM into the RAM memory, so that they can be taken into account during the subsequent operation of the control system. However, EEPROMs require a relatively high operating voltage and have a relatively low data density. In addition, they are costly.
Flash memories (flash RAMs) are also generally known as an alternative to EEPROMs, but they have a limited number of clearing and writing cycles, their number being, for example, not more than just above 10,000. As a result, the service life of a flash memory is often not adequate for the overall number of switching-on and switching-off procedures occurring during the service life of the control system, for example of the motor-vehicle control system, said procedures having corresponding clearing and writing procedures of the flash memory. For example, the overall number of switching-on and switching-off operations of a motor vehicle used frequently for short journeys (for example a taxi) will be several thousand per year, with the result that several tens of thousands of switching-on and switching-off procedures may occur over the service life of the vehicle. If modules were to be used which permit a relatively high number of clearing and writing cycles, this would lead to a significant increase in costs.
In "flash technology replaces EEPROMs" in Design & Elektrotechnik [electrical engineering], Issue 18, 1995, pages 38 to 41, a method which corresponds to the preamble of patent claim 1 is disclosed, in which parameters are stored in a boot-block-flash memory system. In the case of changing parameters, the current parameter values are written successively into a flash memory block and in the parameter which has been set hitherto an indication of the address of the now current parameter is set. When the parameter block is full, the current parameter values are copied into another parameter block and the full parameter block is cleared. As a result of this procedure it is possible to keep the total number of clearing cycles required relatively low. When the system is switched on again, a certain amount of time is, however, required until the respectively current parameter values are found and are available to control the control system.
DE 42 09 905 C1 discloses a system for managing the memory contents of an EEPROM memory which can be overwritten and in which the writing procedures are reduced in number by virtue of the fact that data records which have been newly fed to the system are compared with corresponding data records which are already contained in the memory, and a storage procedure is carried out only if the data records are different.